package com.cosc716.application.gui.components;

import java.awt.Color;
import java.awt.Component;

import javax.swing.BorderFactory;
import javax.swing.JList;
import javax.swing.JTextArea;
import javax.swing.ListCellRenderer;

public class MultiLineCellRenderer extends JTextArea implements ListCellRenderer{

	private static final long serialVersionUID = 8100518475195031686L;

	@Override
	public Component getListCellRendererComponent(JList list, Object value,
			int index, boolean isSelected, boolean cellHasFocus) {
		
		this.setText((String) value);
		this.setBorder(BorderFactory.createMatteBorder(1,0,1,0,Color.black));
		
		return this;
	}
	
}